﻿#-*- coding: utf-8 -*-
#-------------------------------------------------------------------------------
# Name:        if else
# Purpose:
# Author:      SUMMVING
# Created:     2013/08/13  20:17
# Copyright:   (c) SUMMVING 2013
# Licence:     GPLv3
#-------------------------------------------------------------------------------
"""if else"""
a = int(raw_input('input a(0~max)'))  #键盘输入数值
b = int(raw_input('input b'))
if a < b:
   print ('the bigged is b')

else:                            #else以冒号结尾
   print ('the bigged is a')

"""True Flase"""
if True:
   print ('yes you are right')   #如果是真的就输出yes you areright
                                 #否者输出no you are flase
print ('no you are flase')

def fun():                       #定义一个函数fun
    return 1                     #返回 1，为真
if fun():                        #对函数进行判断
   print "it is true"            #为真，输出 it is true

"""more if"""
if  a >= 60:                     #判断 a 的取值范围
   print "a is biggish"

elif 60 > a >= 30:               #如果没有 el，则每个 if都是一个独立的结构，
                                 #那么后面的else会不起作用
   print "a is medium"

elif 30 > a >= 0:
     print "a is smaller"

else:
     print "a is out range"

"""nest if"""                    #nest：嵌套
if a >= 20:                      #该if等效于 if a >= 20 and b >= 20:
   if b >= 20:
        print "a and b are more than 20";
   else:
        print "just a is more than 20"

else:
     print "a is smoll than 20"







